package day1.Base;

public class Test {
    public static void main(String[] args) {
        //向上转型
        Base base = new Derived();
        base.show();
        System.out.println(base.n);
        Derived derived = (Derived) base;
        Fork fork = (Fork) base;//引用类型强制转换运行时异常
    }
}
